{include file="$_admin_document_header_"/}
<body class="hold-transition skin-purple sidebar-mini fixed">
<!-- <body class="hold-transition skin-blue sidebar-mini fixed"> -->
<div class="wrapper">
    <header class="main-header">
      <!-- Logo -->
      <a href="{:url('admin/index/index')}" class="logo" >
       <img class="logo-img" src="__ROOT__/eacoophp_logo_v1.png">  <span class="logo-lg"><b>Eacoo</b>PHP</span>
      </a>
    <!-- Header Navbar: style can be found in header.less -->
    <nav class="navbar navbar-static-top">
      <!-- Sidebar toggle button-->
      <a href="#" class="sidebar-toggle" data-toggle="offcanvas" role="button">
        <span class="sr-only">Toggle navigation</span>
      </a>
      
      {php}if(!IS_MOBILE){{/php}
        <script id="collect_top_menus" type="text/html">
            <a href="#" class="dropdown-toggle" data-toggle="dropdown"><i class="fa fa-star" style="font-size: 20px!important;"></i></a>
            <ul class="dropdown-menu" role="menu">
                <% for (var i = 0; i < data.length; i ++) { %>
                <% var vo = data[i]; %>
                  <li><a href="<%=vo.url %>" class="opentab" tab-name="navtab-collapse-<%=vo.title %>" style="font-weight:bold!important;"><i class="fa fa-circle-o"></i> <%=vo.title %></a></li>
                <% } %>
                <% if (data.length==0) { %>
                    <li class="f13 ml-10 color-6">Tips: 点击<i class="fa fa-star-o"></i>可添加菜单收藏</li>
                <% } %>
            </ul>
        </script>
        <ul class="nav navbar-nav">
          <li id="top-collect-menus"></li>
          <li class="dropdown">
              <a href="#" class="dropdown-toggle fb" data-toggle="dropdown"><i class="fa fa-cloud"></i> 应用中心<span class="label label-danger">新</span> <!-- <span class="caret"></span> --></a>
              <ul class="dropdown-menu" role="menu">
                <li><a href="{:url('admin/modules/index')}" class="opentab" tab-title="应用中心-模块" tab-name="navtab-collapse-app-modules"><img src="/static/admin/img/extension/module.svg" width="16"> 模块</a></li>
                <li><a href="{:url('admin/plugins/index')}" class="opentab" tab-title="应用中心-插件" tab-name="navtab-collapse-app-plugins"><img src="/static/admin/img/extension/plugin.svg" width="16"> 插件</a></li>
                <li><a href="{:url('admin/theme/index')}" class="opentab" tab-title="应用中心-主题" tab-name="navtab-collapse-app-themes"><img src="/static/admin/img/extension/theme.svg" width="16"> 主题</a></li>
              </ul>
            </li>
        </ul>
        <script id="header_modules_menus" type="text/html">
            <% for (var i = 0; i < data.length; i ++) { %>
            <% var vo = data[i]; %>
            <li <% if (vo.default_header_menu_module==1) { %> class="active"<% } %>><a href="#" data-dependtype="1" data-dependflag="<%=vo.name %>" style="font-weight:bold!important;"><i class="<%=vo.icon %>"></i> <%=vo.title %></a></li>
            <% } %>
        </script>
        <ul class="nav navbar-nav" id="header-modules-menus">

        </ul>
      {php}}{/php}
      <div class="navbar-custom-menu">
        <ul class="nav navbar-nav">
          <!-- Messages: style can be found in dropdown.less-->
          <li class="dropdown messages-menu">
            <a href="#" class="dropdown-toggle" data-toggle="dropdown">
              <i class="fa fa-envelope-o"></i>
              <span class="label label-success">{$current_message_count|default='0'}</span>
            </a>
            <ul class="dropdown-menu">
              <li class="header">你有{$current_message_count|default='0'}条消息</li>
              <li class="msg-ul">
                <!-- inner menu: contains the actual data -->
                <ul class="menu msg-list">
                {present name="current_messages"}
                  {volist name="current_messages" id="message"}
                      <li>
                      <a href="{:url('User/Message/message_detail',array('to_uid'=>$message['from_uid']))}" class="popover-toggle" tabindex="0" data-trigger="hover" role="button" data-toggle="popover" data-trigger="focus" data-content="{$message.content}">
                        <div class="pull-left">
                          <img src="{$message.fromuid_avatar|root_full_path=###}" class="img-circle">
                        </div>
                        <h4>{$message.title}<small><i class="fa fa-clock-o"></i> {$message.create_time}</small>
                        </h4>
                        <p>{$message.content|cutStr=###,18}</p>
                      </a>
                    </li>
                  {/volist}
                  {/present}
                </ul>
              </li>
              <li class="footer"><a href="{:url('user/Message/messages',['box_type'=>'inbox'])}">查看所有消息</a></li>
            </ul>
          </li>
          <!-- Notifications: style can be found in dropdown.less -->
          <li class="dropdown notifications-menu">
            <a href="#" class="dropdown-toggle" data-toggle="dropdown">
              <i class="fa fa-bell-o"></i>
              <span class="label label-warning">0</span>
            </a>
            <ul class="dropdown-menu">
              <li class="header">有0条通知</li>
              <li>

                <ul class="menu">
                <li>
                    <a href="#" class="f13 color-6">
                      <i class="fa fa-info text-yellow"></i> 消息内容
                    </a>
                  </li>
                  
                </ul>
              </li>
              <li class="footer"><a href="#">查看所有</a></li>
            </ul>
          </li>

          <!-- User Account: style can be found in dropdown.less -->
          <li class="dropdown user user-menu">
            <a href="#" class="dropdown-toggle" data-toggle="dropdown">
              <img src="{$current_user.avatar|root_full_path|default='/static/assets/img/default-avatar.png'}" class="user-image" alt="{$current_user.nickname}">
              <span class="hidden-xs">{$current_user.nickname}</span>
            </a>
            <ul class="dropdown-menu">
              <!-- User image -->
              <li class="user-header">
                <img src="{$current_user.avatar|root_full_path|default='/static/assets/img/default-avatar.png'}" class="img-circle" alt="User Image">
                <p>
                  {$current_user.nickname} - {/*$current_user.role_name*/}
                  <small>注册时间：{$current_user.create_time}</small>
                </p>
              </li>
              <!-- Menu Body -->
              <!--<li class="user-body">
                <div class="row">
                  <div class="col-xs-4 text-center">
                    <a href="#">关注</a>
                  </div>
                  <div class="col-xs-4 text-center">
                    <a href="#">Sales</a>
                  </div>
                  <div class="col-xs-4 text-center">
                    <a href="#">朋友</a>
                  </div>
                </div>

              </li>-->
              <!-- Menu Footer-->
              <li class="user-footer">
                <div class="pull-left">
                  <a href="{:url('admin/AdminUser/profile',array('uid'=>$current_user['uid']))}" class="btn btn-default btn-flat opentab" tab-name="navtab-collapse-profile">个人资料</a>
                  <a href="{:url('admin/AdminUser/resetPassword',['uid'=>$current_user['uid']])}" class="btn btn-default btn-flat opentab" tab-name="navtab-collapse-resetPassword">修改密码</a>
                </div>
                <div class="pull-right">
                  <a href="javascript:void(0);" class="loginout btn btn-default btn-flat">退出</a>
                </div>
              </li>
            </ul>
          </li>
          <li data-toggle="tooltip" data-placement="bottom" title="" data-original-title="清除缓存">
            <a class="ajax-get" href="{:url('admin/index/delcache')}"><i class="fa f16 fa-trash-o"></i></a>
          </li>
          <li data-toggle="tooltip" data-placement="bottom" title="" data-original-title="打开前台">
            <a href="/" target="_blank"><i class="fa fa-desktop"></i></a>
          </li>
          <li>
            <a href="#" data-toggle="control-sidebar"><i class="fa fa-gears"></i></a>
          </li>
        </ul>
      </div>
    </nav>
  </header>